package com.geekbang.work6.mapper;

import com.geekbang.work6.BookOrder;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;

import java.math.BigInteger;
import java.util.List;

/**
 * @author nhsoft.lul
 */
public interface BookOrderMapper {

    @Select("select * from book_order")
    List<BookOrder> list();

    @Insert("insert into book_order(order_id, customer_id, create_at) values(#{orderId}, #{customerId}, now())")
    void save(long orderId ,long customerId);

    @Delete("delete from book_order")
    void delete();
}
